#-*- coding:utf-8 -*-
import pygame
from plane_sprites import GameSprite


class Bullet1(GameSprite):

    def __init__(self):
        super().__init__("./images/bullet1.png", 0)
        self.speed = 12
        self.active = True
        ##处理图形遮罩
        self.mask = pygame.mask.from_surface(self.image)
    def move(self):
        self.rect.top -= self.speed
        if self.rect.top < 0:
            self.kill()


class Bullet2(GameSprite):
    def __init__(self,position):
        super().__init__("./images/bullet2.png", 0)
        self.speed = 14
        self.active = True
        self.mask = pygame.mask.from_surface(self.image)
    def move(self):
        self.rect.top -= self.speed


